<template>
  <div id="wrap">
    <el-dialog
      title="提示"
      :visible.sync="dialogVisible.sign"
      width="30%">
      <el-form ref="form" :model="formConfig" label-width="80px">

        <el-form-item v-for="(item,index) in formConfig.form" :key="index" :label="item.name">
          <el-input v-model="item.value"></el-input>
        </el-form-item>

        <el-form-item >
          <el-button @click="cancel">取 消</el-button>
          <el-button type="primary" @click="onSubmit(formConfig.form)">确 定</el-button>
        </el-form-item>

      </el-form>
    </el-dialog>
  </div>
</template>

<script>
export default {
  name: "eform",
  data () {
    return {
      
    }
  },
  props: {
    formConfig: {
      type: Object
    },
    dialogVisible: {
      type: Object
    }
  },
  methods: {
    onSubmit(info){
      this.$emit("onSubmit", info)
    },
    cancel(){
      this.$emit("cancel")
    }
  }
}
</script>

<style>

</style>